<?php echo $header; ?>
<div id="main" role="main"> 
            <section id="container">
            	<!-- breadcumbs-->
                <div id="breadcumbs">
                    <ol class="breadcumbs">
                        <li class="first root"><a title="home" href="index.php"></a></li>
                        <li class="item current"><?php echo $info_title;?></li>
                    </ol>
                </div>
                <!-- /breadcumbs-->
                <div class="port">
                
                	<div class="contact-info fll">
                    	<div class="heading-tt">
                            <h1 class="fll"><span><?php echo $info_short;?></span></h1>
                        </div>
                        <div class="contact-content">
                        	<?php echo $info_desc;?>
                        </div>
                    </div>
                    
                    <div class="contact-form flr">
                    	<div class="heading-tt">
                            <h1 class="fll"><span><?php echo $text_title;?></span></h1>
                        </div>
                    	<div class="contact-content">
                        <script type="text/javascript">                   
						$(document).ready(function($) {
								
								$("#contactForm").validate(
									{
										errorPlacement: function(error, element) {			
									},
									invalidHandler: function(form, validator) {
									  var errors = validator.numberOfInvalids();
									if (errors) {
										$('#alert').html(validator['errorList'][0]['message']);
										$('#backoverlay').show();
										$('#show_popup').show();
										$('#f_focus').html(validator['errorList'][0]['element'].name);
										validator['errorList'][0]['element'].focus();
										
									  } else {
									  }
									},
									rules: {
										name : "required",
										email : {
											required: true,
											email: true
										},
										subject : "required",
										message : "required"
										
									},
									messages: {
										name: "<?php echo $txt_error_name;?>",
										email: "<?php echo $txt_error_email;?>",
										subject: "<?php echo $txt_error_enquiry;?>",
										message: "<?php echo $txt_error_message;?>"
									}/*,
									submitHandler: function(form) {
										
											
											
									}*/
								});
								close_popup=function(){		
									var fel=$('#f_focus').html();
									$('#backoverlay').hide();
									$('#show_popup').hide();
									$('#' + fel ).focus();		
							  };
							  reset_form=function(){
									document.forms[0].reset()
							  };
							  
							});
						</script>     
                        	<form action="<?php echo $action; ?>" method="post" enctype="multipart/form-data" name="contactForm" id="contactForm">
                            	<fieldset>
                                	<label><?php echo $entry_name;?><span>*</span></label>
                                    <input type="text"  name="name" id="name" class="input-txt">
                                    <label><?php echo $entry_tel;?>:</label>
                                    <input type="tel" name="phone" class="input-txt" id="phone">
                                    <label><?php echo $entry_email;?><span>*</span></label>
                                    <input type="email" name="email" class="input-txt" id="email">
                                    <label><?php echo $entry_enquiry;?><span>*</span></label>
                                    <input type="text" name="subject" class="input-txt" id="subject">
                                    <label><?php echo $entry_message;?><span>*</span></label>
                                    <textarea name="message" id="message" cols="25" rows="20"></textarea>
                                    <p class="note"><?php echo $entry_notice;?></p>
                                    <div class="form-submit">
                                    	<a onclick="$('#contactForm').submit();" class="form-btn send"><?php echo $text_send;?></a>
                                        <a onclick="$('#contactForm')[0].reset();return false;" class="form-btn reset"><?php echo $text_reset;?></a>
                                    </div>
                                </fieldset>
                            </form>
                        </div>
                    </div>
                    
                </div>
                
                
            </section>
        </div>   
<?php echo $footer; ?>
<?php return;?>





<?php echo $header; ?>
		<div id="main" class="contact">
            <!-- / start main content -->  
            <div id="content" class="prd-category fl-right">
                <?php //echo $mebuu_about_home; ?>
                
               <!-- Breadcumbs  -->
                            	<div id="breadcumbs" class="fl-left">
                                	<ul id="crumbs">
                                        <li><a href=".">Trang chủ</a></li>
                                        <li><span>Liên hệ</span></li>
                                    </ul>
                                </div>
                                <!-- /Breadcumbs  -->
                                <div class="article-content">
                                 	<h1 class="tt-h1">Liên hệ với Shop Mẹ Bưu</h1>
                                	<?php echo $info_end;?>
                                    <h1 class="tt-h1">Form Liên hệ</h1>
                                    <script type="text/javascript">                   
									$(document).ready(function($) {
											
											$.validator.addMethod("check_captcha", function(value, element) 
											{
												$.ajax({
													url: 'index.php?route=information/contact/validate_ajax_captcha',
													type: 'post',
													data: $('#captcha'),
													dataType: 'html',
													success: function(json) {
														/*$('#alert').html(json);
														$('#backoverlay').show();
														$('#show_popup').show();
														$('#f_focus').html(validator['errorList'][0]['element'].name);
														validator['errorList'][0]['element'].focus();
														*/
														$('#captcha_hi').val(json);
														
													}
												});
												
												if(element.value==$('#captcha_hi').val()) {												
													return true;
												} 
												return false;
											});
											
											$("#contactForm").validate(
												{
													errorPlacement: function(error, element) {			
												},
												invalidHandler: function(form, validator) {
												  var errors = validator.numberOfInvalids();
												if (errors) {
													$('#alert').html(validator['errorList'][0]['message']);
													$('#backoverlay').show();
													$('#show_popup').show();
													$('#f_focus').html(validator['errorList'][0]['element'].name);
													validator['errorList'][0]['element'].focus();
													
												  } else {
												  }
												},
												rules: {
													name : "required",
													email : {
														required: true,
														email: true
													},
													message : "required"
													,
													captcha : {
														required: true,
														check_captcha: true
													}
													
												},
												messages: {
													name: "Xin nhập họ tên",
													email: "Xin nhập email",
													message: "Xin nhập lời nhắn",
													captcha: "Xin nhập đúng kí tự"
												}/*,
												submitHandler: function(form) {
													
														$.ajax({
															url: 'index.php?route=information/contact/validate_ajax_captcha',
															type: 'post',
															data: $('#captcha'),
															dataType: 'html',
															success: function(json) {
																$('#alert').html(json);
																$('#backoverlay').show();
																$('#show_popup').show();
																$('#f_focus').html(validator['errorList'][0]['element'].name);
																validator['errorList'][0]['element'].focus();
															}
														});
														
												}*/
											});
											close_popup=function(){		
												var fel=$('#f_focus').html();
												$('#backoverlay').hide();
												$('#show_popup').hide();
												$('#' + fel ).focus();		
										  };
										  reset_form=function(){
												document.forms[0].reset()
										  };
										  
										});
									</script>
                                    <form action="<?php echo $action; ?>" method="post" enctype="multipart/form-data" name="contactForm" id="contactForm">
                                        <fieldset>
                                            <label>Họ tên qúy khách <span class="red">*</span></label>
                                            <input type="text" value="" name="name" id="name">
                                            <label>Email <span class="red">*</span></label>
                                            <input type="text" value="" name="email" id="email">
                                            <label>Điện thoại:</label>
                                            <input type="text" value="" name="phone" id="phone">
                                            <label>Chủ đề:</label>
                                            <input type="text" value="" name="subject" id="subject">
                                            <label>Lời nhắn <span class="red">*</span></label>
                                            <textarea rows="10" cols="10" name="message" id="message"></textarea>
                                            <label><?php echo $entry_captcha; ?> <span class="red">*</span></label>
                                            <input type="text" name="captcha" id="captcha" value="<?php echo $captcha; ?>" />
                                            <input type="hidden" name="captcha_hi" id="captcha_hi" value="" />
                                            <span style="float:left;width: 290px;padding-top:10px;"><img  src="index.php?route=information/contact/captcha" alt="" /></span>
                                            
                                                                                        
                                            <div class="form-submit">
                                                <a onclick="$('#contactForm')[0].reset();return false;" class="btn button fl-left">Hủy</a>
                                                <a onclick="$('#contactForm').submit();" class="btn button fl-left mgl10">Gửi</a>
                                            </div>
                                        </fieldset>
                                    </form>
                                </div>
                                
             </div>
            <!-- sidebar -->
            <div id="sidebar" class="fl-left">
                
                <?php echo $mebuu_left_info_shop; ?>
                
                <?php echo $mebuu_supportonline_home; ?>
                
                
            </div>
        <!-- / end main content -->    
   		</div>
     </div>   
<?php echo $footer; ?>